import React from 'react'
import styles from './index.module.scss'
export default function EditList({ type, config, changeListVisibleHandle }) {
  const list = config[type]
  return (
    <div className={styles.root}>
      {list.map((item, index) => {
        return (
          <div onClick={item.onClick} key={index} className="list-item">
            {item.title}
          </div>
        )
      })}

      <div onClick={changeListVisibleHandle} className="list-item">
        取消
      </div>
    </div>
  )
}
